.oj-navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 20px;
  box-sizing: border-box;
  max-width: 1520px;
  margin: 0 auto;
  transition: all var(--transition-duration) var(--transition-timing);

  .oj-navbar-menus {
    display: flex;
    align-items: center;
    height: 50px;

    .el-menu-item {
      font-family: PingFangSC, PingFang SC;
      font-weight: 400;
      font-size: 20px;
      color: #222222;
      line-height: 28px;
      text-align: center;
      width: 42px;
      text-align: left;
      margin-right: 25px;
      transition: all var(--transition-duration) var(--transition-timing);
      position: relative;

      &::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 0;
        width: 0;
        height: 2px;
        background-color: var(--el-color-primary);
        transition: width var(--transition-duration) var(--transition-timing);
      }

      &:hover {
        color: var(--el-color-primary);
        transform: translateY(-2px);

        &::after {
          width: 100%;
        }
      }

      &.is-active {
        color: var(--el-color-primary);
        font-weight: 600;

        &::after {
          width: 100%;
        }
      }
    }
  }

  .oj-navbar-logo {
    width: 38px;
    height: 38px;
    background: #32C5FF;
    border-radius: 8px;
    cursor: pointer;
    object-fit: contain;
    margin-right: 59px;
    transition: all var(--transition-duration) var(--transition-timing);

    &:hover {
      transform: scale(1.1) rotate(5deg);
      box-shadow: var(--shadow-hover);
    }
  }

  .oj-navbar-menu {
    width: 600px;
    border: none;

    .el-menu-item {
      font-size: 16px;
      font-weight: 500;
      background-color: transparent !important;
      transition: all var(--transition-duration) var(--transition-timing);
      border: none;
      line-height: 60px;
      position: relative;
      overflow: hidden;
      padding: 0 20px;
      margin: 0 10px;
      border-radius: 8px;

      &::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: linear-gradient(45deg, transparent, rgba(50, 197, 255, 0.1), transparent);
        transform: translateX(-100%);
        transition: transform 0.6s var(--transition-timing);
      }

      &::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 50%;
        width: 0;
        height: 3px;
        background: var(--el-color-primary);
        transform: translateX(-50%);
        transition: all var(--transition-duration) var(--transition-timing);
        border-radius: 3px;
      }

      &:hover {
        color: var(--el-color-primary);
        transform: translateY(-2px);
        background-color: rgba(50, 197, 255, 0.05) !important;

        &::before {
          transform: translateX(100%);
        }

        &::after {
          width: 80%;
        }
      }

      &.is-active {
        color: var(--el-color-primary);
        font-weight: 600;
        background-color: rgba(50, 197, 255, 0.1) !important;

        &::after {
          width: 80%;
        }

        &:hover {
          background-color: rgba(50, 197, 255, 0.15) !important;
        }
      }

      &:active {
        transform: scale(var(--active-scale));
      }
    }
  }

  .oj-navbar-users {
    display: flex;
    align-items: center;
  }

  .oj-navbar-login-btn {
    line-height: 60px;
    display: inline-block;
    font-family: PingFangSC, PingFang SC;
    font-weight: 400;
    font-size: 18px;
    color: #222222;
    text-align: center;
    cursor: pointer;
    transition: all var(--transition-duration) var(--transition-timing);
    padding: 0 20px;
    border-radius: 4px;

    &:hover {
      color: var(--el-color-primary);
      background-color: rgba(50, 197, 255, 0.1);
      transform: translateY(-2px);
    }

    &:active {
      transform: scale(var(--active-scale));
    }
  }

  .oj-message {
    cursor: pointer;
    margin-top: 15px;
    transition: all var(--transition-duration) var(--transition-timing);

    &:hover {
      transform: scale(1.1);
    }
  }

  .oj-head-image {
    width: 30px;
    height: 30px;
    border-radius: 30px;
    margin-right: 10px;
    transition: all var(--transition-duration) var(--transition-timing);
    border: 2px solid transparent;

    &:hover {
      transform: scale(1.1);
      border-color: var(--el-color-primary);
    }
  }

  .oj-navbar-name {
    cursor: pointer;
    margin-top: 15px;
    font-weight: 400;
    color: #000;
    margin-left: 15px;
    font-size: 20px;
    width: 100px;
    display: flex;
    align-items: center;
    transition: all var(--transition-duration) var(--transition-timing);
    padding: 5px 10px;
    border-radius: 4px;

    &:hover {
      background-color: rgba(50, 197, 255, 0.1);
      color: var(--el-color-primary);
    }
  }

  .oj-navabar-item {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 32px;
    transition: all var(--transition-duration) var(--transition-timing);

    &:hover {
      background-color: rgba(50, 197, 255, 0.1);
      color: var(--el-color-primary);
    }
  }
}

<style lang="scss" scoped>
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 60px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-sm);
  z-index: 1000;
  transition: all var(--transition-duration) var(--transition-timing);

  &:hover {
    box-shadow: var(--shadow-base);
  }

  .navbar-container {
    max-width: 1520px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 var(--spacing-lg);
  }

  .logo {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    text-decoration: none;
    transition: all var(--transition-duration) var(--transition-timing);

    img {
      width: 32px;
      height: 32px;
      transition: transform var(--transition-duration) var(--transition-timing);
    }

    .logo-text {
      font-size: 20px;
      font-weight: 600;
      color: var(--text-primary);
      transition: color var(--transition-duration) var(--transition-timing);
    }

    &:hover {
      img {
        transform: rotate(15deg);
      }

      .logo-text {
        color: var(--primary-color);
      }
    }
  }

  .nav-menu {
    display: flex;
    align-items: center;
    gap: var(--spacing-xl);

    .nav-item {
      position: relative;
      font-size: 16px;
      color: var(--text-secondary);
      text-decoration: none;
      padding: var(--spacing-sm) var(--spacing-md);
      transition: all var(--transition-duration) var(--transition-timing);

      &::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 50%;
        width: 0;
        height: 2px;
        background: var(--primary-color);
        transition: all var(--transition-duration) var(--transition-timing);
        transform: translateX(-50%);
      }

      &:hover {
        color: var(--primary-color);
        transform: translateY(-2px);

        &::after {
          width: 100%;
        }
      }

      &.active {
        color: var(--primary-color);
        font-weight: 500;

        &::after {
          width: 100%;
        }
      }
    }
  }

  .user-section {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);

    .login-btn {
      padding: var(--spacing-sm) var(--spacing-lg);
      border-radius: var(--border-radius-base);
      background: var(--primary-color);
      color: white;
      border: none;
      cursor: pointer;
      transition: all var(--transition-duration) var(--transition-timing);

      &:hover {
        background: var(--primary-dark);
        transform: translateY(-2px);
        box-shadow: var(--shadow-base);
      }

      &:active {
        transform: scale(var(--active-scale));
      }
    }

    .user-info {
      display: flex;
      align-items: center;
      gap: var(--spacing-sm);
      cursor: pointer;
      padding: var(--spacing-sm);
      border-radius: var(--border-radius-base);
      transition: all var(--transition-duration) var(--transition-timing);

      &:hover {
        background: var(--primary-light);
      }

      .avatar {
        width: 32px;
        height: 32px;
        border-radius: 50%;
        object-fit: cover;
        border: 2px solid var(--primary-color);
        transition: all var(--transition-duration) var(--transition-timing);

        &:hover {
          transform: scale(1.1);
        }
      }

      .username {
        font-size: 14px;
        color: var(--text-primary);
        font-weight: 500;
      }
    }
  }
}

@media screen and (max-width: 768px) {
  .navbar {
    .navbar-container {
      padding: 0 var(--spacing-md);
    }

    .nav-menu {
      display: none;
    }

    .user-section {
      .username {
        display: none;
      }
    }
  }
}
</style> 